package com.hyh.spring.service;

import com.hyh.spring.common.Result;
import com.hyh.spring.model.Payment;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @BelongsPackage: com.hyh.spring.service
 * @ClassName PaymentFeignService
 * @Author: hyhWTX
 * @CreateTime: 2023-04-13  21:33
 * @Description: TODO (一句话描述以下该类的功能)
 * @Version: 1.0
 */
@Component
@FeignClient(value = "CLOUD-PAYMENT-SERVICE")
public interface PaymentFeignService {
    @GetMapping(value = "/payment/get/{id}")
    public Result<Payment> getPaymentById(@PathVariable("id") Long id);

    @GetMapping(value = "/payment/feign/timeout")
    public String paymentFeignTimeout();
}
